/*
* Copyright (c) 2022,MANKA
* All rights reserved.
*
* this is a iot Message  transceiver
*/

@objcMembers public class IotMessageDelegate: NSObject{
    public static let shared = IotMessageDelegate()
    public var sendMessageCallBack : ((Data,UInt32,String,String,Bool) -> Void)?
    private override init(){
    }
    
    public override func copy() -> Any {
           return self // SingletonClass.shared
    }
       
    public override func mutableCopy() -> Any {
        return self // SingletonClass.shared
    }
    
    public func sendIotMessage(message : Data, sequenceNumber: UInt32, from: Address, to: Address, finished: Bool){
        sendMessageCallBack?(message, sequenceNumber, from.hex, to.hex,finished)
    }
}

